home *** CD-ROM | disk | FTP | other *** search
/ C!T ROM 3 / ct-rom iiib.zip / ct-rom iiib / WINDOWS / DIVERSEN / WINE02BX / REMOTE.ELC < prev    next >
Text File  |  1993-03-28  |  10KB  |  103 lines

  1. ;;; compiled by jwz@thalidomide on Thu Jul  2 16:39:16 1992
  2. ;;; from file /u/jwz/emacs19/lisp/packages/remote.el
  3. ;;; emacs version 19.2.1 Lucid.
  4. ;;; bytecomp version 2.07; 17-jun-92.
  5. ;;; optimization is on.
  6. ;;; this file uses opcodes which do not exist in Emacs18.
  7.  
  8. (if (and (boundp 'emacs-version)
  9.      (or (and (boundp 'epoch::version) epoch::version)
  10.          (string-lessp emacs-version "19")))
  11.     (error "This file was compiled for Emacs19."))
  12.  
  13. (defvar default-remote-host "navier:" "\
  14. The host to use for remote file operations when none other is appropriate.")
  15. (defvar track-default-remote-host t "\
  16. Controls whether  default-remote-host  is changed after reading a remote file name.
  17. When non-nil,  default-remote-host  will have the value of the last remote host read.")
  18. (byte-code "└┴!ê┬┴├\"ê└─!ê┼╞!¼ô╟╚!½â╚¬ë╟╔!½â╔¬ü╩╦─ \"¼å═ B └ç" [make-variable-buffer-local buffer-remote-file-name set-default "" remote-editing boundp rcp file-exists-p "/bin/rcp" "/usr/bsd/rcp" "rcp" assoc minor-mode-alist (remote-editing " Remote")] 3)
  19. (fset 'remote-editing #[(arg) "¼ä    ?¬à┬!├V─┼ !ç" [arg remote-editing prefix-numeric-value 0 set-buffer-modified-p buffer-modified-p] 2 "\
  20. Toggle remote-editing mode.
  21. With arg, turn on remote editing mode iff arg is positive, otherwise just toggle it.
  22.  
  23. In remote editing mode, the normal bindings for find-file,
  24. find-file-read-only, find-alternate-file, save-buffer, write-file,
  25. and insert-file are changed to operate on a remote system by default.
  26.  
  27. When remote editing, a prefix arg allows local file operations.  When not
  28. remote editing, a prefix arg allows remote file operations.
  29.  
  30. It is assumed that .rhosts files are set up properly on both machines." "P"])
  31. (byte-code "└┴┬\"ê├─Mê└┼╞\"ç" [global-set-key "r" remote-editing def-local-or-remote (macro . #[(binding name remote local) "└┴\n!!└┴ !!╞╟╔\nDE╦\n╠═╬ ╧╨ ╤╥ ╙░╘╒╓╫\n FD»E*ç" [symbol-name eval remote local l r progn global-set-key binding quote name defun (arg) "Call either " " or " ".\nIf remote-editing (which see), call " ", else call " ".\n\nSee also the documentation for " " and " "." (interactive "P") call-interactively if (xor remote-editing arg)] 18]) "" find-local-or-remote-file] 3)
  32. (fset 'find-local-or-remote-file #[(arg) "└┴\n \"½â─¬ü┼!ç" [call-interactively xor remote-editing arg find-remote-file find-file] 4 "\
  33. Call either find-remote-file or find-file.
  34. If remote-editing (which see), call find-remote-file, else call find-file.
  35.  
  36. See also the documentation for find-remote-file and find-file." "P"])
  37. (global-set-key "" 'find-local-or-remote-file-read-only)
  38. (fset 'find-local-or-remote-file-read-only #[(arg) "└┴\n \"½â─¬ü┼!ç" [call-interactively xor remote-editing arg find-remote-file-read-only find-file-read-only] 4 "\
  39. Call either find-remote-file-read-only or find-file-read-only.
  40. If remote-editing (which see), call find-remote-file-read-only, else call find-file-read-only.
  41.  
  42. See also the documentation for find-remote-file-read-only and find-file-read-only." "P"])
  43. (global-set-key "" 'find-alternate-local-or-remote-file)
  44. (fset 'find-alternate-local-or-remote-file #[(arg) "└┴\n \"½â─¬ü┼!ç" [call-interactively xor remote-editing arg find-alternate-remote-file find-alternate-file] 4 "\
  45. Call either find-alternate-remote-file or find-alternate-file.
  46. If remote-editing (which see), call find-alternate-remote-file, else call find-alternate-file.
  47.  
  48. See also the documentation for find-alternate-remote-file and find-alternate-file." "P"])
  49. (global-set-key "" 'save-local-or-remote-buffer)
  50. (fset 'save-local-or-remote-buffer #[(arg) "└┴\n \"½â─¬ü┼!ç" [call-interactively xor remote-editing arg save-remote-buffer save-buffer] 4 "\
  51. Call either save-remote-buffer or save-buffer.
  52. If remote-editing (which see), call save-remote-buffer, else call save-buffer.
  53.  
  54. See also the documentation for save-remote-buffer and save-buffer." "P"])
  55. (global-set-key "" 'write-local-or-remote-file)
  56. (fset 'write-local-or-remote-file #[(arg) "└┴\n \"½â─¬ü┼!ç" [call-interactively xor remote-editing arg write-remote-file write-file] 4 "\
  57. Call either write-remote-file or write-file.
  58. If remote-editing (which see), call write-remote-file, else call write-file.
  59.  
  60. See also the documentation for write-remote-file and write-file." "P"])
  61. (global-set-key "i" 'insert-local-or-remote-file)
  62. (fset 'insert-local-or-remote-file #[(arg) "└┴\n \"½â─¬ü┼!ç" [call-interactively xor remote-editing arg insert-remote-file insert-file] 4 "\
  63. Call either insert-remote-file or insert-file.
  64. If remote-editing (which see), call insert-remote-file, else call insert-file.
  65.  
  66. See also the documentation for insert-remote-file and insert-file." "P"])
  67. (fset 'find-remote-file #[(host file) "└    \n├#─ë¡╔╟!½å╚!¬╜╔    ╩\n!P! ╚ !ê╠!¼å═╬!ê¬î╧!ê╨─!ê╤!ê    \nP╙ ê╘╒!ê╫ë**ç" [get-remote-file-or-buffer host file "retrieve" nil local-file buffer-or-file bufferp switch-to-buffer generate-new-buffer file-name-nondirectory buf file-exists-p message "(New remote file)" insert-file-contents set-buffer-modified-p delete-file buffer-file-name normal-mode remote-editing 1 buffer-remote-file-name t buffer-offer-save] 5 "\
  68. Edit remote file HOST:FILE (using rcp).
  69. This command is similiar to find-file, but uses rcp to read the file from
  70. a remote machine.  Also see remote-editing." (read-remote-file-name "Find remote file")])
  71. (fset 'find-remote-file-read-only #[nil "└┴!ê┬ëç" [call-interactively find-remote-file t buffer-read-only] 2 "\
  72. Edit remote file FILENAME, but mark buffer as read-only.
  73. Also see find-remote-file and remote-editing." nil])
  74. (fset 'find-alternate-remote-file #[nil "└ ½É    ¼ì┬├─┼ \"!¼ä╞╟!êp┼     ╩╦!ê╠Ä═╬╧╨!\"+ç" [buffer-modified-p buffer-read-only yes-or-no-p format "Buffer %s is modified; kill anyway? " buffer-name error "Aborted" oname obuf rename-buffer " **lose**" ((byte-code "p=½å┴\n!ê¬ä├!ê┴ç" [obuf rename-buffer oname kill-buffer] 2)) apply find-remote-file read-remote-file-name "Find remote alternate file"] 4 "\
  75. Find alternate file using rcp.
  76. This command is similiar to find-alternate-file, but uses rcp to read the file from
  77. a remote machine.  Also see remote-editing." nil])
  78. (fset 'save-remote-buffer #[nil "└ ½Ä    G┬U½ä├─!ç┼    !ç╞╟!ç" [buffer-modified-p buffer-remote-file-name 0 call-interactively write-remote-file do-write-remote-file message "(No changes need to be saved)"] 2 "\
  79. Save a file using rcp.
  80. This command is similiar to save-buffer, but uses rcp to write the file back
  81. to a remote machine.  Also see remote-editing." nil])
  82. (fset 'write-remote-file #[(host file) "└    \nP!ç" [do-write-remote-file host file] 3 "\
  83. Write a file HOST:FILE using rcp.
  84. This command is similiar to write-file, but uses rcp to write the file back
  85. to a remote machine.  Also see remote-editing." (byte-code "└┴┬\"ç" [read-remote-file-name "Write remote file" no-file-ok] 3)])
  86. (fset 'insert-remote-file #[(host file) "└    \n├#ë¡æ┼ !½à╞ !¬ç╟ !ê╚ !)ç" [get-remote-file-or-buffer host file "insert" f-or-b bufferp insert-buffer insert-file delete-file] 5 "\
  87. Insert a remote file HOST:FILE using rcp.
  88. This command is similiar to insert-file, but uses rcp to read the file from
  89. a remote machine.  Also see remote-editing." (read-remote-file-name "Insert remote file")])
  90. (fset 'do-write-remote-file #[(file) "└┴ Pè├─!q┼ ê)╟╔\nî~ê╦ed\n╔╠%ê)═╬\"ê╨╤╥\n%!ë\n½▓½¥╒!╓╫!!P┘!¼à┌!ê█╔!ê)═▌▐ \n#ê▀\n!¬çαß#,ç" ["/tmp/" buffer-name temp get-buffer-create "*Rcp Output*" erase-buffer output t cursor-in-echo-area nil time write-region no-message message "Sending %s..." file process-wait start-process "rcp" rcp remote-editing host-part-only file-name-nondirectory file-part-only new-name get-buffer rename-buffer set-buffer-modified-p buffer-remote-file-name "%d bytes in %d seconds" buffer-size delete-file remote-rcp-error "update"] 7])
  91. (fset 'get-remote-file-or-buffer #[(host file message) "    P┬├    !P─    ╚    !ÿ½ç╔╩!ê─¬├╦!«╜è╠═!q╬ ê)╨╔╥\"ê╙╘╒%!ë½Å╔╫╪┘!8#ê¬ê┌    #*+ç" [host file "/tmp/" file-name-nondirectory nil time temp remote file-name-directory message "Remote directory listing not yet implemented" get-remote-buffer get-buffer-create "*Rcp Output*" erase-buffer output t cursor-in-echo-area "Retrieving %s..." process-wait start-process "rcp" rcp "%d bytes in %d seconds" 7 file-attributes remote-rcp-error] 7 "\
  92. Return a remote file as either a buffer or a file.
  93. If the file HOST:FILE already has been read in, return the buffer
  94. that contains it; otherwise try and rcp the file to the local machine.
  95. If successful, return the local file name."])
  96. (fset 'get-remote-buffer #[(name) "└ïç" [((byte-code "└ ┴\n¼ö ½æ @qê ÿ½â @ A¬i\n*ç" [buffer-list nil found buffers name buffer-remote-file-name] 2))] 1])
  97. (fset 'read-remote-file-name #[(prompt &optional no-file-ok) "└    !«ü\në─┼    !«ü╞!P╔P╩ ╠\"═½â╧¬ü╨\"¼è╠\"¬h└!┼! ½é   ½ë ─ !ÿ½Ö     ╞ÿ¼ç╥┼    !!«ê┼╙ !«é╙ P¬é ,Dç" [host-part-only buffer-remote-file-name default-remote-host host file-name-directory file-part-only "" result prompt " (host:file): " nil file read-no-blanks-input string-match no-file-ok ".+:" ".+:.+" track-default-remote-host file-name-nondirectory buffer-name] 6 "\
  98. Read a remote file specification, and return list (host file).
  99. Prompting with PROMPT, read a string of the form host:file.  The default
  100. value is derived from the remote file name, or if there is none, then
  101. from the global default (default-remote-host)."])
  102. (byte-code "└┴Mê┬├Mê─┼Mê╞╟Mê╚╔Mê╩╦Mç" [host-part-only #[(name) "└┴\n\"¡à\n├ëòOç" [string-match ".+:" name 0] 3] file-part-only #[(name) "└┴\n\"¡å\n├ö├òOç" [string-match ".+:\\(.+\\)" name 1] 3] xor #[(a b) "?    ??=ç" [a b] 2] process-wait #[(proc) "└┬ !─=½ë    T┼╞!ê¬p┬ !╟=¡ê╚ !└=¡ü    )ç" [0 time process-status proc run sleep-for 1 exit process-exit-status] 2] remote-rcp-error #[(buffer file-name message) "└ïç" [((byte-code "└    !ê┬ ê├bê─┼#cêdbê╞╚!ê╔ ê╩    !ç" [switch-to-buffer buffer delete-other-windows 1 format "Unable to %s %s\n\n" message file-name "Hit any character to continue" read-char bury-buffer] 4))] 1] increment-version #[nil "└ ┴ÿ¡Ñ┬ ├ÿ¡ƒèebê─ê┼╞!ê╟uêè╚p!)    ╩ ê    T░c*ç" [user-login-name "raible" buffer-name "remote.el" nil search-backward "." 1 read minor kill-line] 2 nil nil]] 2)
  103.